import { defineStore } from "pinia";

interface stateType {
  isEditItem: boolean;
  attrRow: {
    attrName: string;
    attrValueList: [{ id: number; valueName: string; attrId: number }];
    length: number;
    categoryId: number;
    categoryLevel: number;
    id: number;
  };
}
export const useAttrStroe = defineStore({
  id: "attr",
  state: (): stateType => {
    return {
      isEditItem: false,
      attrRow: {
        attrName: "",
        attrValueList: [] as any,
        length: 0,
        categoryId: 0,
        categoryLevel: 0,
        id: 0,
      },
    };
    // isEditItem:false,
    // attrRow:{}
  },
  actions: {},
  getters: {},
});
